package com.niiwoo.civet.trade.service.local.configure;

import com.niiwoo.civet.trade.dao.entity.BorrowFlowConfig;
import com.niiwoo.civet.trade.dao.entity.InvestFlowConfig;
import com.niiwoo.civet.trade.dao.mapper.BorrowFlowConfigMapperExt;
import com.niiwoo.civet.trade.dao.mapper.InvestFlowConfigMapperExt;
import com.niiwoo.civet.trade.enums.BorrowFlowConfigTypeEnum;
import com.niiwoo.civet.trade.enums.InvestFlowConfigTypeEnum;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * tjb 2018/4/3
 */
@Service
public class BorrowFlowConfigLocalService {

    @Autowired
    private BorrowFlowConfigMapperExt configMapperExt;

    public BorrowFlowConfig queryByType(BorrowFlowConfigTypeEnum type) {
        return configMapperExt.selectByType(type.getValue());
    }

    public List<BorrowFlowConfig> queryList() {
        return configMapperExt.selectList();
    }

}
